Skip to content

Add cross-platform cmark-gfm conversion and release CI - #41

Open
djmsampson wants to merge 104 commits into
masterfrom
cmark
Open

djmsampson wants to merge 104 commits into
masterfrom
cmark

Conversation

@djmsampson

@djmsampson djmsampson commented Nov 14, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Bundle cmark-gfm and gemoji in a local MEX converter; make cmark the offline default.
  • Keep GitHub and GitLab Markdown API converters, unify their request handling in apimd2html, and support private instances through configurable hostnames.
  • Standardize API and MEX error identifiers, validate DNS hostnames, and handle unavailable MATLAB Secrets vaults.
  • Support toolbox packaging before and after R2026b. Expand cross-platform MEX and older-release CI, package all four platform binaries, and add tagged publishing and manually triggered draft releases.
  • Update conversion, build, security, and release documentation.

Validation

  • On MATLAB R2026b, buildtool("test") passed all 27 tests; the MEX rebuilt successfully and code/project checks passed.
  • buildtool("package") succeeded on R2026b.
  • Automated tests do not call the hosted GitHub or GitLab Markdown APIs.

This was linked to issues Nov 21, 2026

@djmsampson djmsampson left a comment •

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Review Comments

  1. P2 — tbx/docmaker/docconvert.m:318: Preserve GitLab LaTeX normalization.

    This now always calls removeItalicTags, but GitLab’s Markdown API returns math in spans marked with data-math-style. Without the removed wrapMathSpans handling, those expressions don’t get $...$ or $$...$$ delimiters, so MathJax won’t render them. Please restore GitLab-specific normalization and cover Converter="gitlab" with Interpreter="latex" using a response fixture.

  2. P2 — src/emoji.c:85: Track inline code spans across lines.

    This scans backtick spans one line at a time. CommonMark code spans can contain line breaks, so a shortcode on a later line inside a span, such as `code\n:smile:\ncode`, gets expanded despite the documented promise to preserve shortcodes in code spans.

  3. P2 — src/emoji.c:45: Validate fenced-code closers.

    is_fence_line accepts any line starting with three or more fence characters. While inside a code block, a line like ```not-a-closer is therefore treated as the closing fence, even though CommonMark requires only whitespace after the fence. Shortcodes later in the block can then be expanded.

  4. P2 — src/emoji.c:130: Handle balanced parentheses in link destinations.

    The destination scan stops at the first ). For a valid destination with balanced parentheses, such as [link](path_(part):smile:), it resumes inside the destination and expands the shortcode, contrary to the documented behavior.

  5. P2 — buildfile.m:208: Exercise the pre-R2026b packaging branch in CI.

    The package task’s older-release license fallback is only covered when UseLicenseBSD is absent. The older-release CI matrix runs tests, not packaging, and does not include R2026a; the package job uses the latest MATLAB. Please add an R2026a package smoke test to exercise this compatibility path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add license to GitHub release No local converter option

1 participant